<template>
	<view>
		<view class="uni-list">
			<block v-for="(item, index) in listData" :key="index">
				<view class="list-item" @click="handleClick(item)">
					<template>
						<slot name="header" :data="item"></slot>
					</template>
					<view v-for="row in rows">
						<view v-if="row.isSlot">
							<slot :name="row.valueName" :data="item"></slot>
						</view>
						<view class="list-row" v-else>
							<view class="list-row-label">{{row.labelName}}</view>
							<view class="list-row-content">{{item[row.valueName]}}</view>
						</view>
					</view>
					<!-- <view class="list-row">
						<view class="list-row-label">当前环节</view>
						<view class="list-row-content">{{item.linkName}}</view>
					</view>
					<view class="list-row">
						<view class="list-row-label">问题来源</view>
						<view class="list-row-content">{{item.caseSource}}</view>
					</view>
					<view class="list-row">
						<view class="list-row-label">案件类型</view>
						<view class="list-row-content">{{item.caseTypeName}}</view>
					</view>
					<view class="list-row">
						<view class="list-row-label">问题描述</view>
						<view class="list-row-content">{{item.caseDesc}}</view>
					</view> -->
					<template>
						<slot name="btns" :data="item"></slot>
					</template>
				</view>
			</block>
		</view>
	</view>
</template>

<script>
	export default {
		name:"case-list-content",
		props: {
			rows:{
				type:Array
			},
			listData:{
				type:Array
			},
			isCustom:{
				type:Boolean
			}
		},
		data() {
			return {
				
			};
		},
		methods:{
			handleClick(item){
				this.$emit('click',item);
			}
		}
	}
</script>

<style>
	.popup-content {
		padding: 15px;
		height: 500px;
		background-color: #fff;
	}
	.list-item{
		padding: 16px;
		border-bottom: 1px solid #F1F1F1;
	}
	.list-row{
		display: flex;
		padding-bottom: 10px;
	}
	.list-row-label{
		font-family: MicrosoftYaHei;
		font-size: 14px;
		font-weight: normal;
		line-height: 17px;
		letter-spacing: 0px;
		color: #9DA0AA;
		width: 25%;
	}
	.list-row-content{
		font-family: MicrosoftYaHei;
		font-size: 14px;
		font-weight: normal;
		line-height: 17px;
		letter-spacing: 0px;
		width: 75%;
		color: #353B50;
		white-space:nowrap;
		text-overflow: ellipsis;
		overflow: hidden;
	}
</style>